from pydantic import BaseModel
from typing import Optional, List

class UploadResponse(BaseModel):
    """上传响应模型"""
    message: str
    files: List[str]
    temp_dir: str

class ProcessRequest(BaseModel):
    """处理请求模型"""
    temp_dir: str
    prompt_type: str = "translate"  # translate, summarize, extract_info, qa
    target_language: Optional[str] = None
    summary_length: Optional[int] = None

    class Config:
        json_schema_extra = {
            "example": {
                "temp_dir": "/path/to/temp/dir",
                "prompt_type": "translate",
                "target_language": "en",
                "summary_length": 500
            }
        }

class ProcessResponse(BaseModel):
    """处理响应模型"""
    status: str
    message: str
    result: str
    output_file: str

class OCRResponse(BaseModel):
    """OCR响应模型"""
    status: str
    message: str
    text: Optional[str] = None
    image_paths: Optional[List[str]] = None 